<template>
<div id="app">
    <input class="ipt" type="text" v-model="message">
    <input class="bth" type="button" value="添加" @click="appendMsg">
    <br>
    <input class="item" type="text">
</div>
</template>
<script>
export default{
    data(){
        return{
          message:"",
          dataList:[],
        }
    },
    methods:{
      appendMsg(){
        this.dataList.push(this.message);
      }
    }
}
</script>
</script>
<style scoped>
.ipt{
  height:40px;
  outline:none;
}
.bth{
  height:40px;
  background:#40b883;
  color:white;
  margin-bottom:20px;

}
.item{
  width:200px;
  height:40px;
  line-height:40px;
  background:#40b883;
  color:white;
  border-bottom:1px solid #ccc;
  margin:0 auto;
}
</style>